package com.ruoyi.project.pm.pview.domain;

import com.ruoyi.project.sedd.order.domain.SellOrderB;
import org.springframework.beans.factory.annotation.Autowired;

import java.util.Date;
import java.util.Objects;

public class PmPview {
    private Integer proId;//项目编号
    private String proType;//项目类型
    private String proStyle;//项目风格
    private String proState;//项目状态
    private Integer proOrderId;//订单编号
    private Date endTime;//结束时间
    private String proSyno;//项目简介

    @Autowired
    private SellOrderB sellOrder; //订单表的值

    public PmPview() {
    }

    public PmPview(Integer proId, String proType, String proStyle, String proState,
                   Integer proOrderId, Date endTime, String proSyno, SellOrderB sellOrder) {
        this.proId = proId;
        this.proType = proType;
        this.proStyle = proStyle;
        this.proState = proState;
        this.proOrderId = proOrderId;
        this.endTime = endTime;
        this.proSyno = proSyno;
        this.sellOrder = sellOrder;
    }

    public Integer getProId() {
        return proId;
    }

    public void setProId(Integer proId) {
        this.proId = proId;
    }

    public String getProType() {
        return proType;
    }

    public void setProType(String proType) {
        this.proType = proType;
    }

    public String getProStyle() {
        return proStyle;
    }

    public void setProStyle(String proStyle) {
        this.proStyle = proStyle;
    }

    public String getProState() {
        return proState;
    }

    public void setProState(String proState) {
        this.proState = proState;
    }

    public Integer getProOrderId() {
        return proOrderId;
    }

    public void setProOrderId(Integer proOrderId) {
        this.proOrderId = proOrderId;
    }

    public Date getEndTime() {
        return endTime;
    }

    public void setEndTime(Date endTime) {
        this.endTime = endTime;
    }

    public String getProSyno() {
        return proSyno;
    }

    public void setProSyno(String proSyno) {
        this.proSyno = proSyno;
    }

    public SellOrderB getSellOrder() {
        return sellOrder;
    }

    public void setSellOrder(SellOrderB sellOrder) {
        this.sellOrder = sellOrder;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        PmPview pmPview = (PmPview) o;
        return Objects.equals(proId, pmPview.proId) &&
                Objects.equals(proType, pmPview.proType) &&
                Objects.equals(proStyle, pmPview.proStyle) &&
                Objects.equals(proState, pmPview.proState) &&
                Objects.equals(proOrderId, pmPview.proOrderId) &&
                Objects.equals(endTime, pmPview.endTime) &&
                Objects.equals(proSyno, pmPview.proSyno) &&
                Objects.equals(sellOrder, pmPview.sellOrder);
    }

    @Override
    public int hashCode() {
        return Objects.hash(proId, proType, proStyle, proState, proOrderId, endTime, proSyno, sellOrder);
    }

    @Override
    public String toString() {
        return "PmPview{" +
                "proId=" + proId +
                ", proType='" + proType + '\'' +
                ", proStyle='" + proStyle + '\'' +
                ", proState='" + proState + '\'' +
                ", proOrderId=" + proOrderId +
                ", endTime=" + endTime +
                ", proSyno='" + proSyno + '\'' +
                ", sellOrder=" + sellOrder +
                '}';
    }
}
